﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;

namespace Wix.Aura.Common {
	public class PermissionEx : IXmlSerializable {
		private PermissionEx() { }
		public PermissionEx(string sddl) {
			Sddl = sddl;
		}

		public string Id { get; set; }
		public string Sddl { get; set; }
		
		public ComponentCondition Condition { get; set; }
		
		public System.Xml.Schema.XmlSchema GetSchema() {
			throw new NotImplementedException();
		}

		public void ReadXml(System.Xml.XmlReader reader) {
			throw new NotImplementedException();
		}

		public void WriteXml(System.Xml.XmlWriter writer) {
			writer.WriteStartElement("PermissionEx");
			writer.WriteAttribute("Id", Id);
			writer.WriteAttribute("Sddl", Sddl);
			writer.WriteElement(Condition);
			writer.WriteEndElement();
		}
	}
}
